
#ifndef  BTREEPLUSPAGENUMBERALLOCATOR_H
#define  BTREEPLUSPAGENUMBERALLOCATOR_H

#include "common.h"

class BtreePlusPageNumberAllocator {
public:
    BtreePlusPageNumberAllocator();
    ~BtreePlusPageNumberAllocator();

    PageNumberType nextPageNo();
    void free(PageNumberType pageNo);

    PageNumberType getNextPageNo(){
        return next;
    }
private:
    PageNumberType next;
    std::list<PageNumberType> freeList;
};


#endif   /* BTREEPLUSPAGENUMBERALLOCATOR_H */
